// Flyweight generator view
// Copyright 2006 (C) Ralph Thomas

#ifndef MISSION_VIEW_GTK_FLYWEIGHT_GENERATOR_H
#define MISSION_VIEW_GTK_FLYWEIGHT_GENERATOR_H

#include <factory.hpp>
#include <view/factory.h>

namespace view {
	//
	/// The flyweight generator is a view similar to the generator,
	/// except that it renders flyweight views instead of real views.
	/// It also includes it's own selection and layout management,
	/// which isn't a large amount of code (and thus no real duplication
	/// of the item/selectable view).
	///
	/// \param	parameters	layout and "bind" (the list of values to show).
	/// \param	parent		the parent widget to insert into.
	/// \param	token		the factory token to create this widget with.
	/// \return	a widget node of ourselves; note that only flyweights
	///			may be children of this widget.
	//
	adobe::widget_node_t flyweight_generator_factory(
			const adobe::dictionary_t&		parameters,
			const adobe::widget_node_t&		parent,
			const adobe::factory_token_t&	token,
			factory*						f);
};

#endif

